<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <!-- 
        ... 运算符将数组转换为  参数序列
     -->

    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <!-- 
         ... 运算符 将数组转换为 参数序列
      -->

    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <!-- 
          ... 运算符 将数组转换为 参数序列
       -->
    <script>
        const BANZHANG = ["1", "2"];
        console.log(...BANZHANG);
        //应用场景
        const A = ["1", "2"];
        const B = ["3", "4"];
        let c = [...A, ...B];
        console.log(c);
        //深拷贝
        const D = [...A];
        D[0] = "5";
        console.log(A);
        console.log(D);
        //将DOM的伪数组变成真正意义上的数组
        let divs = document.getElementsByTagName("div");
        console.log(divs);
        const divArr = [...divs];
        console.log(divArr);

        // const XXX = ["1", "2"];
        // console.log(...XXX);
        // //应用场景
        // const A = ["1", "2"];
        // const B = ["3", "4"];
        // let c = [...A, ...B];
        // console.log(c);
        // //深拷贝
        // const D = [...A];
        // D[0] = "5";
        // console.log(A);
        // console.log(D);
        // //将DOM的伪数组 变成真正意义上的数组
        // let divs = document.getElementsByTagName("div");
        // console.log(divs);
        // const divArr = [...divs];
        // console.log(divArr);

        // const X = ["1", "2"];
        // console.log(...X);
        // //应用场景
        // const A = ["1", "2"];
        // const B = ["3", "4"];
        // let c = [...A, ...B];
        // console.log(c);
        // //深拷贝
        // const D = [...A];
        // D[0] = "6";
        // console.log(A);
        // console.log(D);
        // //讲DOM的伪数组变成真正意义上的数组
        // let divs = document.getElementsByTagName("div");
        // console.log(divs);
        // let divArr = [...divs];
        // console.log(divArr);
    </script>
</body>

</html>